<%@ page import="org.dopdf.document.PDFDocument" %>
<%@ page import="java.io.FileInputStream" %>
<%@ page language="Java" %>
<html>
<head>
<title>The Demo application for do-pdf</title>
</head>
<body>
<p>
    <h2>The web application that wants to embeed the do-pdf viewer</h2>
<%
    final PDFDocument pdfDocument = new PDFDocument(new FileInputStream("E:\\playground\\projarea\\java\\doPDF\\demo\\src\\main\\webapp\\users-guide-R8.pdf"));
%>
<!-- adding the doPDF.css to the web-page -->
<link rel="stylesheet" type="text/css" media="screen" href="/demo/documentviewer/static/styles/doPDF.css"><!-- //required for FF3 and Opera --></link>

<script src="/demo/documentviewer/static/js/jquery/jquery.min.js" type="text/javascript"><!-- //required for FF3 and Opera --></script>

<script src="/demo/documentviewer/static/js/doPDF.js" type="text/javascript"><!-- //required for FF3 and Opera --></script>

<div id="documentViewer" class="viewer">

</div>
<script type="text/javascript">
    $(function() {
        new PDFViewer({
            document: {
                id: "<%=pdfDocument.getId() %>",
                numberOfPages: <%= pdfDocument.getNumberOfPages() %>
            },
            urlParts: {
                contextRoot: "/demo/",
                filterMapping: "documentviewer"
            }
        }).show();
    });
</script>
</p>
</body>
</html>